Book Contents

Attach animation to graphic objects

When you attach animation to an object you define how you want it to behave at run time.

Object animation associates objects with tags or expressions so the appearance or movement of an object changes to reflect changes to a tag's or expression's value. Use the menu options on the Animation menu to open the Animation dialog boxes where you define object behavior. If the animation type is not supported for the selected object, the boxes in the tab are unavailable.

In the animation tabs for horizontal and vertical sliders, you assign a single tag to define animation. For other types of animation, define an expression in the Expression box. Specify how the object's appearance changes based on the result of the expression.

For some types of animation you specify a change of state. For example, an object with visibility animation switches between visible and invisible. For other types of animation, you specify a range of motion. For example, an object can move from a fixed starting point to a fixed end point. The range of motion is related to the minimum and maximum values for the expression. The object moves from the At minimum position to the At maximum position as the expression value changes to the maximum value.

When specifying a tag name you can use an existing HMI tag or direct referenced data item, create a new one, or use a tag placeholder.

You can attach these types of animation to drawing objects: color, fill, height, horizontal position, horizontal slider, rotation, vertical position, vertical slider, visibility, and width. The exceptions are the image and panel objects, which only support visibility animation.

For the other objects and ActiveX controls, you can attach visibility animation only.

Tip:

  • You can attach animation to a group. In general, except for visibility, fill, and color, animation set up for a group of objects takes precedence over animation set up for individual objects within the group.
    • For visibility animation, the Invisible behavior takes precedence.
    • For fill animation, group animation is added to object animation.
    • For color animation, applying color animations to an object group as well as to the individual objects in the group causes unexpected behaviors. To set up color animations for an object group, apply the color animations to the group, or to the individual objects in the group.

      As well, some positioning animation may be additive. Be sure to test group animation to ensure that it produces the effect you intend.

  • If you use a tag's value to control visibility animation as well as in an expression to control some other aspect of animation, when you set up visibility, set the Expression true state to 'Invisible'. If you do not, the object could appear briefly in its design-time location and orientation before animating properly.
  • To open the Animation dialog box, select the object and then, from the View menu, select Animation.

See also

About ActiveX objects

Create graphic displays

Copy and paste animation

Tag names with animation

Tag placeholders

Keywords: animation